package com.zhku.xxl.dao.daoImp;

import com.zhku.xxl.dao.UserDao;
import com.zhku.xxl.entity.User;
import jdbc.GenericDao;

public class UserDaoImp extends GenericDao<User> implements UserDao {

    @Override
    public User findByAccountAndPassword(Object account, Object password, Object username) {
        return super.findByAccountAndPassword(User.class,account,password,username);
    }

    @Override
    public User findById(String id) {
        String sql = "SELECT * FROM user WHERE Id = ?";
        return querySingle(sql,createRowMapper(User.class),id);
    }
}
